<template>
  <div>
    <div>组件插槽</div>
    <slot :obj='obj' name='a'></slot>
    <div>命名插槽</div>
    <slot :obj='obj' name='b'></slot>
  </div>
</template>
<script>
export default {
  name: "slotComponents",
  props: {
    name: {
      type:String,
      default:''
    },
  },
  data() { //数据
    return {
      obj:{
        a:1,
        b:2
      }
    }
  },
  mounted() {
    
  },  
  created() {

  },
  methods: {
   
  },
  components: {

  },
};
</script>
<style scoped lang="less">

</style>